13e9213abb84f47623b20ccc03fbb87e3df6e7a7,extensions/modules/src/org/exist/xquery/modules/mail/MailModule.java,MailModule,storeStore,#XQueryContext#Store#,222

Before Change


	{
		// get the existing stores map from the context
		
		HashMap<Long, Store> stores = (HashMap<Long, Store>)context.getXQueryContextVar( MailModule.STORES_CONTEXTVAR );
		
		if( stores == null ) {
			// if there is no stores map, create a new one
			stores = new HashMap<Long, Store>();
		}

		// get an handle for the store
		long storeHandle = getHandle();

		// place the store in the stores map
		stores.put( new Long( storeHandle ), store );

		// save the updated stores map back in the context
		context.setXQueryContextVar( MailModule.STORES_CONTEXTVAR, stores );

		return( storeHandle );
	}
	
	

After Change


     * 
     * @return A unique handle representing the Store
     */
    static long storeStore(XQueryContext context, Store store) {
        return ModuleUtils.storeObjectInContextMap(context, MailModule.STORES_CONTEXTVAR, store);
    }
	
    /**